<!DOCTYPE html>
<html>
<head lang="en">
    <title>查询结果</title>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width,height=device-height,inital-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">
    <link rel="stylesheet" type="text/css" href="css/reset.css">
    <link rel="stylesheet" type="text/css" href="css/index03.css">
</head>
<body>
<!-- header-->
<div class="header">
    <div><h1>尊敬的客户，</h1> <span>您好!</span></div>
</div>
<div class="word">
    <p>您的车联网信息是：</p>
</div>
<div>
    <form>
        <div class="inputs zh"><span class="name">帐号</span><span class="data" id="name"></span></div>
        <p></p>
        <div class="inputs"><span class="name">初始密码</span><span class="data" id="passwd"></span></div>
        <p></p>
        <div class="inputs"><span class="name">企业名称</span><span class="data" id="entername"></span></div>
        <p></p>
        <div class="inputs address"><span class="name">平台地址</span><span class="data" id="url"></span></div>
    </form>
</div>
<div class="attention">
    <p>如果您使用有问题,欢迎拨打</p>
</div>
<div class="phone"><span>客服电话</span> <span class="phonenumber">400-659-6666</span></div>
<div class="bottom"><p>祝您使用愉快!</p></div>
<script type="text/javascript" src="jquery-1.9.0.min.js"></script>
<script type="text/javascript">
    $(function () {
        var vin=getvalue("vin");
        $("#name").text(getvalue("name"));
        $("#passwd").text(getvalue("password"));
        $("#entername").text(getvalue("entername"))
        var url=getvalue("url");
        url=url.replace(",",", &nbsp;&nbsp;&nbsp;&nbsp;")
        $("#url").html(url);
//        $.ajax({
//            url: "https://eat.vehicleplus.net/voss/ent/getEntLoginInfo?token=PCDoWJMPwloLBrsoGrt&vin="+vin,
//            type: 'GET',
//            async: true,
//            success: function (data) {
//                console.log("data", data)
//                if (parseInt(data.code) == 0) {
//                    $("#name").text(getvalue("name"));
//                    $("#passwd").text(getvalue("password"));
//                    $("#entername").text(data.data.entName)
//                    $("#url").text(getvalue("url"));
////                    location.href = "./index03.html?name=" + data.data.loginname + "&password=" + data.data.password + "&url=" + data.data.appEditions[0].url+"&entername="+data.data.entName
//                } else {
////                    location.href = "./index02.html";
//                }
//            },
//            error: function (xhr) {
//                console.log("error")
////                location.href = "./index02.html";
//            }
//        });
    });
    function getvalue(name) {
        var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
        var search = window.location.search;
        search=decodeURI(search);
        var r = search.substr(1).match(reg);
        if (r != null) return unescape(r[2]);
        return null;
    }
</script>
</body>
</html>